package com.neusoft.databus.core.vo;

import com.excel.poi.annotation.ExportField;
import com.excel.poi.annotation.ImportField;

import lombok.Getter;
import lombok.Setter;

/**
 * 网关导入导出VO
 *
 * @author naxiang
 */
@Getter
@Setter
public class GatewayPortVO {
    /**
     * 网关code
     */
    @ExportField(columnName = "网关编码")
    private String code;
    /**
     * 网关名称
     */
    @ExportField(columnName = "网关名称")
    @ImportField(required = true)
    private String name;
    /**
     * 网关连接方式
     */
    @ExportField(columnName = "网关连接方式")
    @ImportField(required = true)
    private String physicalConnType;
    /**
     * 网关连接信息
     */
    @ExportField(columnName = "网关连接信息")
    @ImportField(required = true)
    private String config;
    /**
     * 网关工作模式
     */
    @ExportField(columnName = "网关工作模式")
    @ImportField(required = true)
    private String workMode;
    /**
     * 建立连接的超时时间（秒），默认2秒
     */
    @ImportField(required = false, regex = "^\\d*$", regexMessage = "建立连接的超时时间（秒）必须为数字")
    public Integer connectTimeout;
    /**
     * 连接失败后的重试次数，默认不重试
     */
    @ImportField(required = false, regex = "^\\d*$", regexMessage = "连接失败后的重试次数必须为数字")
    public Integer connectRetry;
}
